// SPDX-License-Identifier: GPL-2.0
//
// mtk-dsp-common_define.h --  Mediatek ADSP common define
//
// Copyright (c) 2018 MediaTek Inc.
// Author: Chipeng <Chipeng.chang@mediatek.com>


#ifndef AUDIO_DSP_COMMON_DEFINE_H
#define AUDIO_DSP_COMMON_DEFINE_H

#include <audio_playback_msg_id.h>

/* task command param1 */
enum {
	AUDIO_DSP_TASK_PCM_HWPARAM_DL = 0x1,
	AUDIO_DSP_TASK_PCM_HWPARAM_UL = 0x2,
	AUDIO_DSP_TASK_PCM_HWPARAM_REF = 0x4,
};

enum {
	AUDIO_TASK_VOIP_ID = 0,
	AUDIO_TASK_PRIMARY_ID,
	AUDIO_TASK_OFFLOAD_ID,
	AUDIO_TASK_DEEPBUFFER_ID,
	AUDIO_TASK_PLAYBACK_ID,
	AUDIO_TASK_MUSIC_ID,
	AUDIO_TASK_CAPTURE_UL1_ID,
	AUDIO_TASK_A2DP_ID,
	AUDIO_TASK_DATAPROVIDER_ID,
	AUDIO_TASK_CALL_FINAL_ID,
	AUDIO_TASK_FAST_ID,
	AUDIO_TASK_KTV_ID,
	AUDIO_TASK_CAPTURE_RAW_ID,
	AUDIO_TASK_DAI_NUM = (AUDIO_TASK_CAPTURE_RAW_ID - AUDIO_TASK_VOIP_ID + 1),
};

enum {
	AUDIO_DSP_AFE_SHARE_MEM_ID = 0,
	AUDIO_DSP_SHARE_MEM_NUM,
};

enum {
	MEMORY_AUDIO_SRAM,
	MEMORY_AUDIO_DRAM,
	MEMORY_SYSTEM_TCM,
};

enum{
	BUFFER_TYPE_SHARE_MEM,
	BUFFER_TYPE_HW_MEM
};

enum {
	ADSP_TASK_ATTR_DEFAULT,
	ADSP_TASK_ATTR_MEMDL,
	ADSP_TASK_ATTR_MEMUL,
	ADSP_TASK_ATTR_MEMREF,
	ADSP_TASK_ATTR_RUMTIME,
	ADSP_TASK_ATTR_FEATUREID,
	ADSP_TASK_ATTR_SMARTPA,
	ADSP_TASK_ATTR_REF_RUNTIME,
	ADSP_TASK_ATTR_NUM
};

/* dl consume param2 status */
enum {
	ADSP_DL_CONSUME_OK,
	ADSP_DL_CONSUME_RESET,
	ADSP_DL_CONSUME_UNDERFLOW,
};


#endif
